package com.njtoyo.taxi.admin.mapper.master.entity;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.njtoyo.taxi.admin.mapper.master.enums.*;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;


/**
 * <p>
 * 
 * </p>
 *
 * @author Dell
 * @since 2021-07-05
 */
@Data
@EqualsAndHashCode(callSuper = false)
@ApiModel(value="CouponTemplate对象", description="")
public class CouponTemplate implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "主键")
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    @ApiModelProperty(value = "商品标题")
    private String title;

    @ApiModelProperty(value = "优惠券类型")
    private CouponCategory category;

    @ApiModelProperty(value = "优惠券面值")
    private BigDecimal couponValue;

    @ApiModelProperty(value = "规格参数")
    private String specifics;

    @ApiModelProperty(value = "适用范围：0:mix,1:realtime,2:appointment")
    private CouponScope scope;

    @ApiModelProperty(value = "适用平台 0:mix[通用],1:app,2:wxmina[小程序],3:h5")
    private CouponPlatform platform;

    @ApiModelProperty(value = "来源渠道 0:system[平台发放],1:activity_team[助力]")
    private CouponSourceChannel sourceChannel;

    @ApiModelProperty(value = "使用条件")
    private CouponUsageCondition usageCondition;

    @ApiModelProperty(value = "使用限制")
    private String usageLimit;

    @ApiModelProperty(value = "优惠券生效时间")
    private Long effectiveAfter;

    @ApiModelProperty(value = "优惠券生效时间段")
    private Long effectiveDuration;

    @ApiModelProperty(value = "创建时间")
    @TableField(fill = FieldFill.INSERT)
    private Date createdAt;

    @ApiModelProperty(value = "修改时间")
    @TableField(fill = FieldFill.INSERT_UPDATE)
    private Date updatedAt;


}
